<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="js/vue/2.5.16/vue.min.js"></script>
    <script src="js/axios/0.17.1/axios.min.js"></script>
</head>
<body>
<div id="app">
    {{uid}}--{{uname}}
    <button @click="load">点击</button>
    <form method="post" action="/userTest">
        <input type="text" value="" name="username">
        <input type="submit" value="提交">
    </form>
    <p id="inpChange"> {{message}}
        <input v-model="message">
</div>

详情页面
<script>
    var app = new Vue({
        el: '#app',
        data: {
            message: 'Hello Vue!',
            user: '',
            uri: "userdetail",
            uname: '',
            uid: '',
            message: 'zheshi '
        }, methods: {
            load: function () {
                let url = this.uri;
                this.message = "aaaa";
                console.log(url)
                var _self = this;
                axios.get(url).then(response => {
                    _self.uid = response.data.id;
                    console.log(_self.uid)
                });
            }
        }
    })
</script>
</body>
</html>